package com.wwm.petadopt;

import org.json.JSONObject;

/**
 * Created by maaibin on 2015/5/24.
 */
public class PetDetail {
    public String petId;
    public String petType;
    public String petName;
    public String petSex;
    public String petAge;
    public String petVariety;
    public String adoptionAgency;
    public String adoptionAddress;
    public String phoneNum;
    public String introduce;
    public String imageUrl;
    public String adoptFlag;

    public PetDetail(JSONObject response){
        try {
            this.petId = response.getString("id");
            this.petType = response.getString("aniType");
            this.petName = response.getString("aniName");
            this.petSex = response.getString("sex");
            this.petAge = response.getString("age");
            this.petVariety = response.getString("type_name");
            this.adoptionAgency = response.getString("adopt_name");
            this.adoptionAddress = response.getString("adopt_addr");
            this.phoneNum = response.getString("phone");
            this.introduce = response.getString("introduce");
            this.imageUrl = GlobalData.SERVER + response.getString("image");
            this.adoptFlag = response.getString("adoptflag");
        }
        catch(Exception e)
        {}

    }
}